package com.huqu.entities;

import java.io.Serializable;
import java.sql.Timestamp;
import java.sql.Types;

import com.huqu.basedao.QbMapping;
import com.huqu.utils.ApplicationConstant;
import com.huqu.utils.ApplicationHelper;

public class N200 implements Serializable {

	private static final long serialVersionUID = 5832352440473320715L;

	@QbMapping(name = "idmuc", typeMapping = Types.INTEGER)
	private int idmuc;
	
	@QbMapping(name = "idtheloai", typeMapping = Types.INTEGER)
	private int idtheloai;
	
	@QbMapping(name = "idbaiviet", typeMapping = Types.INTEGER)
	private int idbaiviet;
	private String md5baiviet;
	
	@QbMapping(name = "tentheloai", typeMapping = Types.CHAR)
	private String tentheloai;
	
	private String tentheloai_vi;
	private String tentheloai_en;
	
	@QbMapping(name = "tieude", typeMapping = Types.CHAR)
	private String tieude;
	
	@QbMapping(name = "hinhanh", typeMapping = Types.CHAR)
	private String hinhanh;
	private String hinhanh_name;
	
	@QbMapping(name = "nguoitao", typeMapping = Types.INTEGER)
	private int nguoitao;
	
	@QbMapping(name = "nguoicapnhat", typeMapping = Types.INTEGER)
	private int nguoicapnhat;
	
	@QbMapping(name = "daxoa", typeMapping = Types.INTEGER)
	private int daxoa;
	
	@QbMapping(name = "kiemduyet", typeMapping = Types.INTEGER)
	private int kiemduyet;
	
	@QbMapping(name = "uutien", typeMapping = Types.INTEGER)
	private int uutien;
	
	@QbMapping(name = "luotxem", typeMapping = Types.INTEGER)
	private int luotxem;
	
	@QbMapping(name = "tgtao", typeMapping = Types.TIMESTAMP )
	private Timestamp tgtao;
	
	@QbMapping(name = "tgcapnhat", typeMapping = Types.TIMESTAMP)
	private Timestamp tgcapnhat;

	
//------------------------------------------------------------------------------------------------------------------
//------------------------------------------------------------------------------------------------------------------
	public int getIdmuc() {
		return idmuc;
	}

	public void setIdmuc(int idmuc) {
		this.idmuc = idmuc;
	}

	public int getIdtheloai() {
		return idtheloai;
	}

	public void setIdtheloai(int idtheloai) {
		this.idtheloai = idtheloai;
	}

	public int getIdbaiviet() {
		return idbaiviet;
	}

	public void setIdbaiviet(int idbaiviet) {
		this.idbaiviet = idbaiviet;
	}

	public String getMd5baiviet() {
		if(idbaiviet!=0){
			md5baiviet=ApplicationHelper.convertToMD5(String.valueOf(idbaiviet));
		}
		return md5baiviet;
	}

	public void setMd5baiviet(String md5baiviet) {
		this.md5baiviet = md5baiviet;
	}

	public String getTentheloai() {
		return tentheloai;
	}

	public void setTentheloai(String tentheloai) {
		this.tentheloai = tentheloai;
	}

	public String getTentheloai_vi() {
		return tentheloai_vi;
	}

	public void setTentheloai_vi(String tentheloai_vi) {
		this.tentheloai_vi = tentheloai_vi;
	}

	public String getTentheloai_en() {
		return tentheloai_en;
	}

	public void setTentheloai_en(String tentheloai_en) {
		this.tentheloai_en = tentheloai_en;
	}

	public String getTieude() {
		return tieude;
	}

	public void setTieude(String tieude) {
		this.tieude = tieude;
	}

	public String getHinhanh() {
		if(hinhanh==null){
			hinhanh=ApplicationConstant.URL_NO_IMAGE;
		}
		return hinhanh;
	}

	public String getHinhanh_name() {
		return hinhanh_name;
	}

	public void setHinhanh_name(String hinhanh_name) {
		this.hinhanh_name = hinhanh_name;
	}

	public void setHinhanh(String hinhanh) {
		this.hinhanh = hinhanh;
	}

	public int getNguoitao() {
		return nguoitao;
	}

	public void setNguoitao(int nguoitao) {
		this.nguoitao = nguoitao;
	}

	public int getNguoicapnhat() {
		return nguoicapnhat;
	}

	public void setNguoicapnhat(int nguoicapnhat) {
		this.nguoicapnhat = nguoicapnhat;
	}

	public int getDaxoa() {
		return daxoa;
	}

	public void setDaxoa(int daxoa) {
		this.daxoa = daxoa;
	}

	public int getKiemduyet() {
		return kiemduyet;
	}

	public void setKiemduyet(int kiemduyet) {
		this.kiemduyet = kiemduyet;
	}

	public int getUutien() {
		return uutien;
	}

	public void setUutien(int uutien) {
		this.uutien = uutien;
	}

	public int getLuotxem() {
		return luotxem;
	}

	public void setLuotxem(int luotxem) {
		this.luotxem = luotxem;
	}

	public Timestamp getTgtao() {
		return tgtao;
	}

	public void setTgtao(Timestamp tgtao) {
		this.tgtao = tgtao;
	}

	public Timestamp getTgcapnhat() {
		return tgcapnhat;
	}

	public void setTgcapnhat(Timestamp tgcapnhat) {
		this.tgcapnhat = tgcapnhat;
	}
	
	
}
